package com.foxire.demo;

public class Test {
  public static void main(String[] args) {
       // 目标：完成面向对象综合小案例
       // 1.设计电影类Movie，以便创建电影对象，封装电影数据
       // 2.封装系统中的全部电影数据
       Movie[] movies = new Movie[6];
       // movies = [null, null, null, null]
       movies[0] = new Movie("《星际穿越》", 1, "张艺谋", 20.0);
       movies[1] = new Movie("《盗梦空间》", 2, "李晨", 15.0);
       movies[2] = new Movie("《星际大戰》", 3, "星际", 25.0);
       movies[3] = new Movie("《星際大戰：終結者3》", 4, "拯救者", 30.0);
       movies[4] = new Movie("《霍元甲》", 5, "霍元甲", 35.0);
       movies[5] = new Movie("《黄飞鸿》", 6, "李连杰", 40.0);

       // 3.创建电脑操作对象出来，负责电脑数据的业务操作，完成电影数据的添加、修改、删除、查询、显示等操作
       MovieOperator movieOperator = new MovieOperator(movies);
       movieOperator.printMovie();
       movieOperator.searchMovie();
  }

}
